<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<!-- NewPage -->
<html lang="en">
<head>
<title>ReadOnlySharedStringsTable (POI API Documentation)</title>
<link rel="stylesheet" type="text/css" href="../../../../../stylesheet.css" title="Style">
</head>
<body>
<script type="text/javascript"><!--
    if (location.href.indexOf('is-external=true') == -1) {
        parent.document.title="ReadOnlySharedStringsTable (POI API Documentation)";
    }
//-->
</script>
<noscript>
<div>JavaScript is disabled on your browser.</div>
</noscript>
<!-- ========= START OF TOP NAVBAR ======= -->
<div class="topNav"><a name="navbar_top">
<!--   -->
</a><a href="#skip-navbar_top" title="Skip navigation links"></a><a name="navbar_top_firstrow">
<!--   -->
</a>
<ul class="navList" title="Navigation">
<li><a href="../../../../../overview-summary.html">Overview</a></li>
<li><a href="package-summary.html">Package</a></li>
<li class="navBarCell1Rev">Class</li>
<li><a href="class-use/ReadOnlySharedStringsTable.html">Use</a></li>
<li><a href="package-tree.html">Tree</a></li>
<li><a href="../../../../../deprecated-list.html">Deprecated</a></li>
<li><a href="../../../../../index-all.html">Index</a></li>
<li><a href="../../../../../help-doc.html">Help</a></li>
</ul>
</div>
<div class="subNav">
<ul class="navList">
<li>PREV CLASS</li>
<li><a href="../../../../../org/apache/poi/xssf/eventusermodel/XSSFReader.html" title="class in org.apache.poi.xssf.eventusermodel"><span class="strong">NEXT CLASS</span></a></li>
</ul>
<ul class="navList">
<li><a href="../../../../../index.html?org/apache/poi/xssf/eventusermodel/ReadOnlySharedStringsTable.html" target="_top">FRAMES</a></li>
<li><a href="ReadOnlySharedStringsTable.html" target="_top">NO FRAMES</a></li>
</ul>
<ul class="navList" id="allclasses_navbar_top">
<li><a href="../../../../../allclasses-noframe.html">All Classes</a></li>
</ul>
<div>
<script type="text/javascript"><!--
  allClassesLink = document.getElementById("allclasses_navbar_top");
  if(window==top) {
    allClassesLink.style.display = "block";
  }
  else {
    allClassesLink.style.display = "none";
  }
  //-->
</script>
</div>
<div>
<ul class="subNavList">
<li>SUMMARY:&nbsp;</li>
<li>NESTED&nbsp;|&nbsp;</li>
<li>FIELD&nbsp;|&nbsp;</li>
<li><a href="#constructor_summary">CONSTR</a>&nbsp;|&nbsp;</li>
<li><a href="#method_summary">METHOD</a></li>
</ul>
<ul class="subNavList">
<li>DETAIL:&nbsp;</li>
<li>FIELD&nbsp;|&nbsp;</li>
<li><a href="#constructor_detail">CONSTR</a>&nbsp;|&nbsp;</li>
<li><a href="#method_detail">METHOD</a></li>
</ul>
</div>
<a name="skip-navbar_top">
<!--   -->
</a></div>
<!-- ========= END OF TOP NAVBAR ========= -->
<!-- ======== START OF CLASS DATA ======== -->
<div class="header">
<p class="subTitle">org.apache.poi.xssf.eventusermodel</p>
<h2 title="Class ReadOnlySharedStringsTable" class="title">Class ReadOnlySharedStringsTable</h2>
</div>
<div class="contentContainer">
<ul class="inheritance">
<li>java.lang.Object</li>
<li>
<ul class="inheritance">
<li>org.xml.sax.helpers.DefaultHandler</li>
<li>
<ul class="inheritance">
<li>org.apache.poi.xssf.eventusermodel.ReadOnlySharedStringsTable</li>
</ul>
</li>
</ul>
</li>
</ul>
<div class="description">
<ul class="blockList">
<li class="blockList">
<dl>
<dt>All Implemented Interfaces:</dt>
<dd>org.xml.sax.ContentHandler, org.xml.sax.DTDHandler, org.xml.sax.EntityResolver, org.xml.sax.ErrorHandler</dd>
</dl>
<hr>
<br>
<pre>public class <strong>ReadOnlySharedStringsTable</strong>
extends org.xml.sax.helpers.DefaultHandler</pre>
<div class="block"><p>This is a lightweight way to process the Shared Strings
  table. Most of the text cells will reference something
  from in here.
 <p>Note that each SI entry can have multiple T elements, if the
  string is made up of bits with different formatting.
 <p>Example input:
 <pre>
&lt;?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
&lt;sst xmlns="http://schemas.openxmlformats.org/spreadsheetml/2006/main" count="2" uniqueCount="2">
 &lt;si>
   &lt;r>
     &lt;rPr>
       &lt;b />
       &lt;sz val="11" />
       &lt;color theme="1" />
       &lt;rFont val="Calibri" />
       &lt;family val="2" />
       &lt;scheme val="minor" />
     &lt;/rPr>
     &lt;t>This:&lt;/t>
   &lt;/r>
   &lt;r>
     &lt;rPr>
       &lt;sz val="11" />
       &lt;color theme="1" />
       &lt;rFont val="Calibri" />
       &lt;family val="2" />
       &lt;scheme val="minor" />
     &lt;/rPr>
     &lt;t xml:space="preserve">Causes Problems&lt;/t>
   &lt;/r>
 &lt;/si>
 &lt;si>
   &lt;t>This does not&lt;/t>
 &lt;/si>
&lt;/sst>
 </pre></div>
</li>
</ul>
</div>
<div class="summary">
<ul class="blockList">
<li class="blockList">
<!-- ======== CONSTRUCTOR SUMMARY ======== -->
<ul class="blockList">
<li class="blockList"><a name="constructor_summary">
<!--   -->
</a>
<h3>Constructor Summary</h3>
<table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Constructor Summary table, listing constructors, and an explanation">
<caption><span>Constructors</span><span class="tabEnd">&nbsp;</span></caption>
<tr>
<th class="colOne" scope="col">Constructor and Description</th>
</tr>
<tr class="altColor">
<td class="colOne"><code><strong><a href="../../../../../org/apache/poi/xssf/eventusermodel/ReadOnlySharedStringsTable.html#ReadOnlySharedStringsTable(org.apache.poi.openxml4j.opc.OPCPackage)">ReadOnlySharedStringsTable</a></strong>(<a href="../../../../../org/apache/poi/openxml4j/opc/OPCPackage.html" title="class in org.apache.poi.openxml4j.opc">OPCPackage</a>&nbsp;pkg)</code>&nbsp;</td>
</tr>
<tr class="rowColor">
<td class="colOne"><code><strong><a href="../../../../../org/apache/poi/xssf/eventusermodel/ReadOnlySharedStringsTable.html#ReadOnlySharedStringsTable(org.apache.poi.openxml4j.opc.PackagePart, org.apache.poi.openxml4j.opc.PackageRelationship)">ReadOnlySharedStringsTable</a></strong>(<a href="../../../../../org/apache/poi/openxml4j/opc/PackagePart.html" title="class in org.apache.poi.openxml4j.opc">PackagePart</a>&nbsp;part,
                          <a href="../../../../../org/apache/poi/openxml4j/opc/PackageRelationship.html" title="class in org.apache.poi.openxml4j.opc">PackageRelationship</a>&nbsp;rel_ignored)</code>
<div class="block">Like POIXMLDocumentPart constructor</div>
</td>
</tr>
</table>
</li>
</ul>
<!-- ========== METHOD SUMMARY =========== -->
<ul class="blockList">
<li class="blockList"><a name="method_summary">
<!--   -->
</a>
<h3>Method Summary</h3>
<table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Method Summary table, listing methods, and an explanation">
<caption><span>Methods</span><span class="tabEnd">&nbsp;</span></caption>
<tr>
<th class="colFirst" scope="col">Modifier and Type</th>
<th class="colLast" scope="col">Method and Description</th>
</tr>
<tr class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><strong><a href="../../../../../org/apache/poi/xssf/eventusermodel/ReadOnlySharedStringsTable.html#characters(char[], int, int)">characters</a></strong>(char[]&nbsp;ch,
          int&nbsp;start,
          int&nbsp;length)</code>
<div class="block">Captures characters only if a t(ext) element is open.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><strong><a href="../../../../../org/apache/poi/xssf/eventusermodel/ReadOnlySharedStringsTable.html#endElement(java.lang.String, java.lang.String, java.lang.String)">endElement</a></strong>(java.lang.String&nbsp;uri,
          java.lang.String&nbsp;localName,
          java.lang.String&nbsp;name)</code>&nbsp;</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>int</code></td>
<td class="colLast"><code><strong><a href="../../../../../org/apache/poi/xssf/eventusermodel/ReadOnlySharedStringsTable.html#getCount()">getCount</a></strong>()</code>
<div class="block">Return an integer representing the total count of strings in the workbook.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>java.lang.String</code></td>
<td class="colLast"><code><strong><a href="../../../../../org/apache/poi/xssf/eventusermodel/ReadOnlySharedStringsTable.html#getEntryAt(int)">getEntryAt</a></strong>(int&nbsp;idx)</code>
<div class="block">Return the string at a given index.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>java.util.List&lt;java.lang.String&gt;</code></td>
<td class="colLast"><code><strong><a href="../../../../../org/apache/poi/xssf/eventusermodel/ReadOnlySharedStringsTable.html#getItems()">getItems</a></strong>()</code>&nbsp;</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>int</code></td>
<td class="colLast"><code><strong><a href="../../../../../org/apache/poi/xssf/eventusermodel/ReadOnlySharedStringsTable.html#getUniqueCount()">getUniqueCount</a></strong>()</code>
<div class="block">Returns an integer representing the total count of unique strings in the Shared String Table.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><strong><a href="../../../../../org/apache/poi/xssf/eventusermodel/ReadOnlySharedStringsTable.html#readFrom(java.io.InputStream)">readFrom</a></strong>(java.io.InputStream&nbsp;is)</code>
<div class="block">Read this shared strings table from an XML file.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><strong><a href="../../../../../org/apache/poi/xssf/eventusermodel/ReadOnlySharedStringsTable.html#startElement(java.lang.String, java.lang.String, java.lang.String, org.xml.sax.Attributes)">startElement</a></strong>(java.lang.String&nbsp;uri,
            java.lang.String&nbsp;localName,
            java.lang.String&nbsp;name,
            org.xml.sax.Attributes&nbsp;attributes)</code>&nbsp;</td>
</tr>
</table>
<ul class="blockList">
<li class="blockList"><a name="methods_inherited_from_class_org.xml.sax.helpers.DefaultHandler">
<!--   -->
</a>
<h3>Methods inherited from class&nbsp;org.xml.sax.helpers.DefaultHandler</h3>
<code>endDocument, endPrefixMapping, error, fatalError, ignorableWhitespace, notationDecl, processingInstruction, resolveEntity, setDocumentLocator, skippedEntity, startDocument, startPrefixMapping, unparsedEntityDecl, warning</code></li>
</ul>
<ul class="blockList">
<li class="blockList"><a name="methods_inherited_from_class_java.lang.Object">
<!--   -->
</a>
<h3>Methods inherited from class&nbsp;java.lang.Object</h3>
<code>clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait</code></li>
</ul>
</li>
</ul>
</li>
</ul>
</div>
<div class="details">
<ul class="blockList">
<li class="blockList">
<!-- ========= CONSTRUCTOR DETAIL ======== -->
<ul class="blockList">
<li class="blockList"><a name="constructor_detail">
<!--   -->
</a>
<h3>Constructor Detail</h3>
<a name="ReadOnlySharedStringsTable(org.apache.poi.openxml4j.opc.OPCPackage)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>ReadOnlySharedStringsTable</h4>
<pre>public&nbsp;ReadOnlySharedStringsTable(<a href="../../../../../org/apache/poi/openxml4j/opc/OPCPackage.html" title="class in org.apache.poi.openxml4j.opc">OPCPackage</a>&nbsp;pkg)
                           throws java.io.IOException,
                                  org.xml.sax.SAXException</pre>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>pkg</code> - </dd>
<dt><span class="strong">Throws:</span></dt>
<dd><code>java.io.IOException</code></dd>
<dd><code>org.xml.sax.SAXException</code></dd>
<dd><code>javax.xml.parsers.ParserConfigurationException</code></dd></dl>
</li>
</ul>
<a name="ReadOnlySharedStringsTable(org.apache.poi.openxml4j.opc.PackagePart, org.apache.poi.openxml4j.opc.PackageRelationship)">
<!--   -->
</a>
<ul class="blockListLast">
<li class="blockList">
<h4>ReadOnlySharedStringsTable</h4>
<pre>public&nbsp;ReadOnlySharedStringsTable(<a href="../../../../../org/apache/poi/openxml4j/opc/PackagePart.html" title="class in org.apache.poi.openxml4j.opc">PackagePart</a>&nbsp;part,
                          <a href="../../../../../org/apache/poi/openxml4j/opc/PackageRelationship.html" title="class in org.apache.poi.openxml4j.opc">PackageRelationship</a>&nbsp;rel_ignored)
                           throws java.io.IOException,
                                  org.xml.sax.SAXException</pre>
<div class="block">Like POIXMLDocumentPart constructor</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>part</code> - </dd><dd><code>rel_ignored</code> - </dd>
<dt><span class="strong">Throws:</span></dt>
<dd><code>java.io.IOException</code></dd>
<dd><code>org.xml.sax.SAXException</code></dd></dl>
</li>
</ul>
</li>
</ul>
<!-- ============ METHOD DETAIL ========== -->
<ul class="blockList">
<li class="blockList"><a name="method_detail">
<!--   -->
</a>
<h3>Method Detail</h3>
<a name="readFrom(java.io.InputStream)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>readFrom</h4>
<pre>public&nbsp;void&nbsp;readFrom(java.io.InputStream&nbsp;is)
              throws java.io.IOException,
                     org.xml.sax.SAXException</pre>
<div class="block">Read this shared strings table from an XML file.</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>is</code> - The input stream containing the XML document.</dd>
<dt><span class="strong">Throws:</span></dt>
<dd><code>java.io.IOException</code> - if an error occurs while reading.</dd>
<dd><code>org.xml.sax.SAXException</code></dd>
<dd><code>javax.xml.parsers.ParserConfigurationException</code></dd></dl>
</li>
</ul>
<a name="getCount()">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getCount</h4>
<pre>public&nbsp;int&nbsp;getCount()</pre>
<div class="block">Return an integer representing the total count of strings in the workbook. This count does not
 include any numbers, it counts only the total of text strings in the workbook.</div>
<dl><dt><span class="strong">Returns:</span></dt><dd>the total count of strings in the workbook</dd></dl>
</li>
</ul>
<a name="getUniqueCount()">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getUniqueCount</h4>
<pre>public&nbsp;int&nbsp;getUniqueCount()</pre>
<div class="block">Returns an integer representing the total count of unique strings in the Shared String Table.
 A string is unique even if it is a copy of another string, but has different formatting applied
 at the character level.</div>
<dl><dt><span class="strong">Returns:</span></dt><dd>the total count of unique strings in the workbook</dd></dl>
</li>
</ul>
<a name="getEntryAt(int)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getEntryAt</h4>
<pre>public&nbsp;java.lang.String&nbsp;getEntryAt(int&nbsp;idx)</pre>
<div class="block">Return the string at a given index.
 Formatting is ignored.</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>idx</code> - index of item to return.</dd>
<dt><span class="strong">Returns:</span></dt><dd>the item at the specified position in this Shared String table.</dd></dl>
</li>
</ul>
<a name="getItems()">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getItems</h4>
<pre>public&nbsp;java.util.List&lt;java.lang.String&gt;&nbsp;getItems()</pre>
</li>
</ul>
<a name="startElement(java.lang.String, java.lang.String, java.lang.String, org.xml.sax.Attributes)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>startElement</h4>
<pre>public&nbsp;void&nbsp;startElement(java.lang.String&nbsp;uri,
                java.lang.String&nbsp;localName,
                java.lang.String&nbsp;name,
                org.xml.sax.Attributes&nbsp;attributes)
                  throws org.xml.sax.SAXException</pre>
<dl>
<dt><strong>Specified by:</strong></dt>
<dd><code>startElement</code>&nbsp;in interface&nbsp;<code>org.xml.sax.ContentHandler</code></dd>
<dt><strong>Overrides:</strong></dt>
<dd><code>startElement</code>&nbsp;in class&nbsp;<code>org.xml.sax.helpers.DefaultHandler</code></dd>
<dt><span class="strong">Throws:</span></dt>
<dd><code>org.xml.sax.SAXException</code></dd></dl>
</li>
</ul>
<a name="endElement(java.lang.String, java.lang.String, java.lang.String)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>endElement</h4>
<pre>public&nbsp;void&nbsp;endElement(java.lang.String&nbsp;uri,
              java.lang.String&nbsp;localName,
              java.lang.String&nbsp;name)
                throws org.xml.sax.SAXException</pre>
<dl>
<dt><strong>Specified by:</strong></dt>
<dd><code>endElement</code>&nbsp;in interface&nbsp;<code>org.xml.sax.ContentHandler</code></dd>
<dt><strong>Overrides:</strong></dt>
<dd><code>endElement</code>&nbsp;in class&nbsp;<code>org.xml.sax.helpers.DefaultHandler</code></dd>
<dt><span class="strong">Throws:</span></dt>
<dd><code>org.xml.sax.SAXException</code></dd></dl>
</li>
</ul>
<a name="characters(char[], int, int)">
<!--   -->
</a>
<ul class="blockListLast">
<li class="blockList">
<h4>characters</h4>
<pre>public&nbsp;void&nbsp;characters(char[]&nbsp;ch,
              int&nbsp;start,
              int&nbsp;length)
                throws org.xml.sax.SAXException</pre>
<div class="block">Captures characters only if a t(ext) element is open.</div>
<dl>
<dt><strong>Specified by:</strong></dt>
<dd><code>characters</code>&nbsp;in interface&nbsp;<code>org.xml.sax.ContentHandler</code></dd>
<dt><strong>Overrides:</strong></dt>
<dd><code>characters</code>&nbsp;in class&nbsp;<code>org.xml.sax.helpers.DefaultHandler</code></dd>
<dt><span class="strong">Throws:</span></dt>
<dd><code>org.xml.sax.SAXException</code></dd></dl>
</li>
</ul>
</li>
</ul>
</li>
</ul>
</div>
</div>
<!-- ========= END OF CLASS DATA ========= -->
<!-- ======= START OF BOTTOM NAVBAR ====== -->
<div class="bottomNav"><a name="navbar_bottom">
<!--   -->
</a><a href="#skip-navbar_bottom" title="Skip navigation links"></a><a name="navbar_bottom_firstrow">
<!--   -->
</a>
<ul class="navList" title="Navigation">
<li><a href="../../../../../overview-summary.html">Overview</a></li>
<li><a href="package-summary.html">Package</a></li>
<li class="navBarCell1Rev">Class</li>
<li><a href="class-use/ReadOnlySharedStringsTable.html">Use</a></li>
<li><a href="package-tree.html">Tree</a></li>
<li><a href="../../../../../deprecated-list.html">Deprecated</a></li>
<li><a href="../../../../../index-all.html">Index</a></li>
<li><a href="../../../../../help-doc.html">Help</a></li>
</ul>
</div>
<div class="subNav">
<ul class="navList">
<li>PREV CLASS</li>
<li><a href="../../../../../org/apache/poi/xssf/eventusermodel/XSSFReader.html" title="class in org.apache.poi.xssf.eventusermodel"><span class="strong">NEXT CLASS</span></a></li>
</ul>
<ul class="navList">
<li><a href="../../../../../index.html?org/apache/poi/xssf/eventusermodel/ReadOnlySharedStringsTable.html" target="_top">FRAMES</a></li>
<li><a href="ReadOnlySharedStringsTable.html" target="_top">NO FRAMES</a></li>
</ul>
<ul class="navList" id="allclasses_navbar_bottom">
<li><a href="../../../../../allclasses-noframe.html">All Classes</a></li>
</ul>
<div>
<script type="text/javascript"><!--
  allClassesLink = document.getElementById("allclasses_navbar_bottom");
  if(window==top) {
    allClassesLink.style.display = "block";
  }
  else {
    allClassesLink.style.display = "none";
  }
  //-->
</script>
</div>
<div>
<ul class="subNavList">
<li>SUMMARY:&nbsp;</li>
<li>NESTED&nbsp;|&nbsp;</li>
<li>FIELD&nbsp;|&nbsp;</li>
<li><a href="#constructor_summary">CONSTR</a>&nbsp;|&nbsp;</li>
<li><a href="#method_summary">METHOD</a></li>
</ul>
<ul class="subNavList">
<li>DETAIL:&nbsp;</li>
<li>FIELD&nbsp;|&nbsp;</li>
<li><a href="#constructor_detail">CONSTR</a>&nbsp;|&nbsp;</li>
<li><a href="#method_detail">METHOD</a></li>
</ul>
</div>
<a name="skip-navbar_bottom">
<!--   -->
</a></div>
<!-- ======== END OF BOTTOM NAVBAR ======= -->
<p class="legalCopy"><small>
                <i>Copyright 2014 The Apache Software Foundation or
        its licensors, as applicable.</i>
            </small></p>
</body>
</html>
